Sheffield | 25-ITP-Sep | Xiayidan Abuxuukuer | Sprint 2 | Coursework#781
Sheffield | 25-ITP-Sep | Xiayidan Abuxuukuer | Sprint 2 | Coursework#781Shayida999 wants to merge 10 commits intoCodeYourFuture:mainfrom
Conversation
|
Your PR's title isn't in the expected format. Please check the expected title format, and update yours to match. Reason: Wrong number of parts separated by |s If this PR is not coursework, please add the NotCoursework label (and message on Slack in #cyf-curriculum or it will probably not be noticed). |
|
Your PR's title isn't in the expected format. Please check the expected title format, and update yours to match. Reason: Wrong number of parts separated by |s If this PR is not coursework, please add the NotCoursework label (and message on Slack in #cyf-curriculum or it will probably not be noticed). |
1 similar comment
|
Your PR's title isn't in the expected format. Please check the expected title format, and update yours to match. Reason: Wrong number of parts separated by |s If this PR is not coursework, please add the NotCoursework label (and message on Slack in #cyf-curriculum or it will probably not be noticed). |
|
Your PR's title isn't in the expected format. Please check the expected title format, and update yours to match. Reason: Wrong number of parts separated by |s If this PR is not coursework, please add the NotCoursework label (and message on Slack in #cyf-curriculum or it will probably not be noticed). |
cjyuan
left a comment
There was a problem hiding this comment.
-
Code and explanation look good. I only have a few suggestions.
-
This branch is not quite clean. Can you practice using the
gitcommands you learned to revert the changes made to the file not related to the Sprint-2 exercise?
| function calculateBMI (weight,height) { | ||
|
|
||
| let bmi = weight / (height*height) | ||
|
|
||
| return bmi.toFixed(1) | ||
|
|
||
| } |
There was a problem hiding this comment.
What type of value do you expect the function to return? A number or a string?
Does your function return the type of value you expect?
| let hours = Number(time.slice(0, 2)); | ||
| let mins = time.slice(3); |
There was a problem hiding this comment.
When a variable is not going to be re-assigned a value, it is best practices to declare it using const instead of let (to convey the message that it is a constant and also to prevent it from being accidently reassigned a value).
There was a problem hiding this comment.
Thanks CJ i fixed both, and reverted sprint 1.
Learners, PR Template
Self checklist
Changelist
Questions
none for now thanks.